#ifndef TSERIALPORT_H
#define TSERIALPORT_H

#include <QIODevice>
#include <QSerialPort>

class SerialPort : public QSerialPort
{
    Q_OBJECT
private:
    QString mPortName;

public:
    explicit SerialPort(QString port, QObject *parent = nullptr);
    virtual ~SerialPort();

    virtual void close();
    virtual bool open(QIODevice::OpenMode flags);

protected:
    virtual qint64 writeData(const char *data, qint64 maxSize);


signals:

public slots:
};

#endif // TSERIALPORT_H
